home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World Komputer 2010 April
/
PCWorld0410.iso
/
redakcyjne
/
programy
/
Tlen 6.0.1.12 pl
/
tleninst60112.exe
/
sdk
/
Plugin_src
/
basic-vc
/
demoplugin.cpp
< prev
next >
Wrap
C/C++ Source or Header
|
2006-09-18
|
1KB
|
61 lines
// demoplugin.cpp : Defines the entry point for the DLL application.
//
#include "stdafx.h"
#include "../../TlenSources/plugin/plugin_struct.h"
#include "AggressiveOptimize.h"
#include <stdio.h>
HINSTANCE hInst;
TLENPLUGINFUNCTIONS *tlen_functions;
TLENPLUGININFO pluginInfo={
sizeof(TLENPLUGININFO),
"Nazwa pluginu",
PLUGIN_API_VERSION,
MAKE_DWORD_VERSION(1,2,3,4),
"Opis pluginu",
"⌐ Prawa autorskie",
"Producent",
"E@mail",
"http://www",
0,
0,
0,
0
};
extern "C" __declspec(dllexport) TLENPLUGININFO* GetPluginInfo(DWORD TlenVersion);
extern "C" __declspec(dllexport) int LoadPlugin(TLENPLUGINFUNCTIONS *tlen_functions);
extern "C" __declspec(dllexport) int UnloadPlugin(void);
BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
{
hInst=hinstDLL;
return TRUE;
}
__declspec(dllexport) TLENPLUGININFO* GetPluginInfo(DWORD tlenVersion)
{
char buf[16];
sprintf(buf, "%d", tlenVersion);
MessageBox(NULL, "Wersja tlenu", buf, MB_OK);
return &pluginInfo;
}
__declspec(dllexport) int LoadPlugin(TLENPLUGINFUNCTIONS *functions)
{
tlen_functions = functions;
MessageBox(NULL, "Plugin za│adowany", "Prosty plugin VC++", MB_OK);
return 0;
}
__declspec(dllexport) int UnloadPlugin(void)
{
MessageBox(NULL, "Plugin wy│adowany", "Prosty plugin VC++", MB_OK);
return 0;
}